tools/libxl: return socket id from libxl_psr_cat_get_l3_info
authorChao Peng <chao.p.peng@linux.intel.com>
Tue, 29 Sep 2015 07:49:52 +0000 (15:49 +0800)
committerIan Campbell <ian.campbell@citrix.com>
Tue, 29 Sep 2015 09:56:22 +0000 (10:56 +0100)
commit30e7a6fde8d4810a230324b89125b4bdc8e5374d
treec443ebbc9222f6c0e5df34b46f7c90d852286886
parenta4943f6bdd2bcef9e20020a74e41aaeb77e42905
tools/libxl: return socket id from libxl_psr_cat_get_l3_info

The entries returned from libxl_psr_cat_get_l3_info are assumed
to be socket-continuous. But this is not true in the hotplug case.

This patch gets the socket bitmap for all the sockets on the system
first and stores the socket id in the structure libxl_psr_cat_info in
libxl_psr_cat_get_l3_info. The xl or similar consumers then can display
socket information correctly.

Signed-off-by: Chao Peng <chao.p.peng@linux.intel.com>
Reviewed-by: Dario Faggioli <dario.faggioli@citrix.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
tools/libxl/libxl_psr.c
tools/libxl/libxl_types.idl
tools/libxl/xl_cmdimpl.c